package com.kayt.cyberBar.cuser.business.entity.po;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

/**
 * BPositionTaskRes entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "b_position_task_res")
public class BPositionTaskRes implements java.io.Serializable {

	// Fields

	/**
	 * 
	 */
	private static final long serialVersionUID = -4342971260921593543L;
	private Long id;
	private String taskCode;
	private String description;
	private String taskDate;
	private String taskStartTime;
	private String taskEndTime;
	private String fulfilStatus;
	private String taskCircleTypeCode;
	private String taskCircleCode;
	private String createTime;
	private String updateTime;
	private String statusCode;

	private BPositionTask positionTask;
	
	private BPositionTaskDetail positionTaskDetail;
	// Constructors

	/** default constructor */
	public BPositionTaskRes() {
	}

	/** full constructor */
	public BPositionTaskRes(String taskCode, String description,
			String taskDate, String taskStartTime, String taskEndTime,
			String fulfilStatus, String createTime, String updateTime,
			String statusCode) {
		this.taskCode = taskCode;
		this.description = description;
		this.taskDate = taskDate;
		this.taskStartTime = taskStartTime;
		this.taskEndTime = taskEndTime;
		this.fulfilStatus = fulfilStatus;
		this.createTime = createTime;
		this.updateTime = updateTime;
		this.statusCode = statusCode;
	}

	// Property accessors
	@Id
	@GeneratedValue
	@Column(name = "ID", unique = true, nullable = false)
	public Long getId() {
		return this.id;
	}

	public void setId(Long id) {
		this.id = id;
	}
	@Column(name = "TASK_CIRCLE_TYPE_CODE", length = 64)
	public String getTaskCircleTypeCode() {
		return taskCircleTypeCode;
	}

	public void setTaskCircleTypeCode(String taskCircleTypeCode) {
		this.taskCircleTypeCode = taskCircleTypeCode;
	}
	@Column(name = "TASK_CIRCLE_CODE", length = 64)
	public String getTaskCircleCode() {
		return taskCircleCode;
	}

	public void setTaskCircleCode(String taskCircleCode) {
		this.taskCircleCode = taskCircleCode;
	}

	@Column(name = "TASK_CODE", length = 64)
	public String getTaskCode() {
		return this.taskCode;
	}

	public void setTaskCode(String taskCode) {
		this.taskCode = taskCode;
	}

	@Column(name = "DESCRIPTION", length = 1024)
	public String getDescription() {
		return this.description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	@Column(name = "TASK_DATE", length = 64)
	public String getTaskDate() {
		return this.taskDate;
	}

	public void setTaskDate(String taskDate) {
		this.taskDate = taskDate;
	}

	@Column(name = "TASK_START_TIME", length = 64)
	public String getTaskStartTime() {
		return this.taskStartTime;
	}

	public void setTaskStartTime(String taskStartTime) {
		this.taskStartTime = taskStartTime;
	}

	@Column(name = "TASK_END_TIME", length = 64)
	public String getTaskEndTime() {
		return this.taskEndTime;
	}

	public void setTaskEndTime(String taskEndTime) {
		this.taskEndTime = taskEndTime;
	}

	@Column(name = "FULFIL_STATUS", length = 64)
	public String getFulfilStatus() {
		return this.fulfilStatus;
	}

	public void setFulfilStatus(String fulfilStatus) {
		this.fulfilStatus = fulfilStatus;
	}

	@Column(name = "CREATE_TIME", length = 64)
	public String getCreateTime() {
		return this.createTime;
	}

	public void setCreateTime(String createTime) {
		this.createTime = createTime;
	}

	@Column(name = "UPDATE_TIME", length = 64)
	public String getUpdateTime() {
		return this.updateTime;
	}

	public void setUpdateTime(String updateTime) {
		this.updateTime = updateTime;
	}

	@Column(name = "STATUS_CODE", length = 64)
	public String getStatusCode() {
		return this.statusCode;
	}

	public void setStatusCode(String statusCode) {
		this.statusCode = statusCode;
	}

	@OneToOne(targetEntity = BPositionTask.class, fetch = FetchType.EAGER)
	@JoinColumn(name="TASK_CODE", referencedColumnName="TASK_CODE", nullable = true,insertable=false ,updatable=false)
	public BPositionTask getPositionTask() {
		return positionTask;
	}

	public void setPositionTask(BPositionTask positionTask) {
		this.positionTask = positionTask;
	}

	@OneToOne(targetEntity = BPositionTaskDetail.class, fetch = FetchType.LAZY)
	@JoinColumn(name="TASK_CODE", referencedColumnName="TASK_CODE", nullable = true,insertable=false ,updatable=false)
	public BPositionTaskDetail getPositionTaskDetail() {
		return positionTaskDetail;
	}

	public void setPositionTaskDetail(BPositionTaskDetail positionTaskDetail) {
		this.positionTaskDetail = positionTaskDetail;
	}

}